import api from '@/api/api'
import '@/api/mock.js'
import '@/assets/less/index.less'
import * as ElementPlusIconsVue from '@element-plus/icons-vue'
import ElementPlus from 'element-plus'
import 'element-plus/dist/index.css'
import { createPinia } from 'pinia'
import { createApp } from 'vue'
import App from './App.vue'
import router from './router'

const app = createApp(App);
// axios
app.config.globalProperties.$api = api;

// 3. pinia
app.use(createPinia());

// 2. element-plus
app.use(ElementPlus);
for (const [key, component] of Object.entries(ElementPlusIconsVue)) {
    app.component(key, component)
  }
// 1. 引入路由
app.use(router);
app.mount('#app');

